{% load time_filters %}
<div class="card">
  <div class="card-header border-0">
    <h3 class="card-title">文章访问区</h3>
    <div class="card-tools">
      <button type="button" class="btn btn-tool" data-card-widget="collapse">
        <i class="fas fa-minus"></i>
      </button>
    </div>
  </div>
  <div class="card-body table-responsive p-0">
    <table class="table table-striped table-valign-middle">
      <thead>
        <tr>
          <th width="15%">排名</th>
          <th width="30%">标题</th>
          <th>当日访问量</th>
          <th>发布日期</th>
        </tr>
      </thead>
      <tbody>
        {% if post_view_table_list %}
            {% for post_view in post_view_table_list  %}
        <tr>
          <td>{{ forloop.counter }}</td>
          <td>
            <a
              href="{% url 'post:detail' time_id=post_view.time_id %}"
              class="text-muted"
              >{{ post_view.title }}</a
            >
          </td>
          <td>{{ post_view.inscrease }}</td>
          <td>{{ post_view.publish_time | data_format_y_m_d }}</td>
        </tr>
            {% endfor %}
        {% endif %}
      </tbody>
    </table>
  </div>
</div>